home *** CD-ROM | disk | FTP | other *** search
/ Mastering Web Site Development / Microsoft Mastering Web Site Development (Microsoft) (1997).iso / Media / Ch08 / W08D020.cc2 < prev    next >
Encoding:
Text File  |  1997-04-24  |  2.7 KB  |  49 lines

  1. 0, In this demonstration, you will see how to create 
  2. 4, a new ActiveX DLL project in Visual Basic 5.0, and 
  3. 7, how to set properties for the project. To create a 
  4. 11, new project in Visual Basic 5.0, choose File, New 
  5. 15, Project. There are several types of projects you 
  6. 19, can choose from. Standard EXE creates a standard 
  7. 23, Windows program. ActiveX EXE creates an executable 
  8. 28, that is an automation server. ActiveX DLL creates 
  9. 32, a dynamic link library that is an automation 
  10. 34, server, as well. And ActiveX control creates a control 
  11. 38, with a graphical interface that can be used in 
  12. 40, ActiveX control containers. Since we are creating 
  13. 44, ActiveX server components, I will choose ActiveX DLL. 
  14. 51, Once the project is created, you can see all the 
  15. 53, files that are in the project by looking at the 
  16. 56, Project Explorer. Here we can see that a new class 
  17. 60, module, called Class1, was created by default. You 
  18. 66, can set properties for the project by choosing 
  19. 68, Project, Project1 Properties. In the Project 
  20. 75, Properties dialog box, you can change settings that affect 
  21. 78, the whole project. The project type determines 
  22. 82, the type of project. Since I initially selected 
  23. 85, ActiveX DLL, the type is set to ActiveX DLL. The 
  24. 90, startup object allows you to indicate what object is 
  25. 92, called when the DLL runs. By default it is set to 
  26. 96, none, since ActiveX DLLs are normally started by other 
  27. 100, programs. However, you could write a sub Main to 
  28. 104, contain code to run every time the DLL is loaded. 
  29. 108, The project name is the beginning part of the 
  30. 111, ProgID. For example, if I name this project Math and 
  31. 116, later name a class module Square, an outside program 
  32. 120, would create the class module by using the name 
  33. 123, Math.Square. If you have a Help file for this 
  34. 126, project, you can make it part of the project by 
  35. 128, providing its path in Help File Name. You can also 
  36. 132, indicate the Context ID to be used when someone browses 
  37. 136, for default help. The project description provides 
  38. 140, a human readable description of the project. For 
  39. 143, example, since this Math project contains objects 
  40. 146, that perform math functions, I could name it Math 
  41. 150, Objects. The project description will show up in 
  42. 154, the object browser when someone browses this DLL, and 
  43. 157, when someone makes a library reference to it. 
  44. 161, Unattended execution indicates that the user will not 
  45. 164, interact with the DLL. Checking this box will 
  46. 167, make your DLL apartment threaded. Once you have set 
  47. 170, the project properties, you are ready to add methods 
  48. 173, and code to create an ActiveX server component.
  49. 177, END